/*******************************************************************************
 * Copyright (c) 2011 squid.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 * 
 * Contributors:
 *     squid - initial API and implementation
 ******************************************************************************/
package com.google.code.cubeirc.common;

import java.util.HashMap;

import org.eclipse.swt.graphics.Color;
import org.eclipse.swt.widgets.Display;


/**
 * Class with application info
 * @author squid
 *
 */
public final class ApplicationInfo {
	
	
	//Application info
	public static String APP_NAME = "CubeIRC";
	public static String APP_VERSION = "v1.0";
	public static String APP_REVISION = "r04";
	public static String[] APP_AUTHORS = {"squid <me@creazionicreative.it>"};
	public static String APP_WEB = "http://code.google.com/p/cubeirc/";
	public static String APP_ICON = "/com/google/code/cubeirc/resources/ApplicationIcon.png";
	public static String APP_UPDATE_URL = "http://code.google.com/feeds/p/cubeirc/downloads/basic";
	public static String APP_TICKETS_URL = "http://code.google.com/p/cubeirc/issues/list";
	public static String APP_MOTD_URL = "http://www.creazionicreative.it/cubeirc/motd";
	public static String APP_FULL = String.format("%s %s", APP_NAME, APP_VERSION);
	
	
	//Plugins info
	public static String PLG_DEFAULT_DIRECTORY = "plugins";
	public static String PLG_DEFAULT_FILE = "plugins.xml";
	public static String PLG_PLUGINS = String.format("%s%s%s", PLG_DEFAULT_DIRECTORY, Utils.getDirSeparator(), PLG_DEFAULT_FILE);
	
	
	//Config info
	public static String CFG_DEFAULT_DIRECTORY = "conf";
	public static String CFG_DEFAULT_FILE = "settings.xml";
	public static String CFG_SETTINGS = String.format("%s%s%s", CFG_DEFAULT_DIRECTORY, Utils.getDirSeparator(), CFG_DEFAULT_FILE);
	
	
	//Files Received
	public static String DCC_DEFAULT_DIRECTORY = "received" + Utils.getDirSeparator();
	
	
	//Connection settings info
	public static String CNS_DEFAULT_DIRECTORY = "conf";
	public static String CNS_DEFAULT_FILE = "servers.xml";
	public static String CNS_SERVERS = String.format("%s%s%s", CNS_DEFAULT_DIRECTORY, Utils.getDirSeparator(), CNS_DEFAULT_FILE);
	
	
	//Colors settings 
	public static String CLS_DEFAULT_DIRECTORY = "conf";
	public static String CLS_DEFAULT_FILE = "colors.xml";
	public static String CLS_COLORS = String.format("%s%s%s", CLS_DEFAULT_DIRECTORY, Utils.getDirSeparator(), CLS_DEFAULT_FILE);
	//Default colors
	public static String CLS_COLOR_GLOBAL = "Global";	
	public static String CLS_COLOR_NOTICE = "Notice";		
	public static String CLS_COLOR_USERMSG = "User message";
	public static String CLS_COLOR_ACTION = "Action";
	public static String CLS_COLOR_MODE = "Mode";
	public static String CLS_COLOR_ERROR = "Error";
	
	
	//Editor info defaults
	public static String  EDT_DEFAULT_NAME = "EDITOR_Default";
	public static String  EDT_PRIVATEMSG_NAME = "EDITOR_PrivateMessage";
	public static String  EDT_INPUTCONSOLE_NAME = "EDITOR_Input_console";
	public static String  EDT_CHANNEL_INPUT_NAME = "EDITOR_Input_console";
	public static String  EDT_CHANNEL_OUTPUT_NAME = "EDITOR_Input_output";
	public static String  EDT_CHANNEL_TOPIC_NAME = "EDITOR_Input_topic";
	
	public static String  EDT_CONSOLE_NAME = "EDITOR_Console";
	public static String  EDT_DEFAULT_FONTNAME = "Lucida Console";
	public static int    EDT_DEFAULT_FONTSIZE = 10;
	public static Color  EDT_DEFAULT_FOREGROUND = new Color(Display.getCurrent(), 0, 0, 0);
	public static Color  EDT_DEFAULT_BACKGROUND = new Color(Display.getCurrent(), 255, 255, 255);
	public static int   EDT_DEFAULT_MAX_LINES = 2000;
	
	
	//Tab names
	public static String TAB_DEBUGGER = "Debugger";
	public static String TAB_CONFIG = "Configuration";
	public static String TAB_SERVERS = "Servers";
	public static String TAB_IRCCONSOLE = "IRC Console";
	public static String TAB_CHANNELSLIST = "Channels list";
	public static String TAB_DOWNLOADS = "Downloads";
	
	//Requirement libs
	public static String LIBS_BASE_URL = "http://www.creazionicreative.it/cubeirc/libs/";
	
	//public static String[] LIBS_TODOWNLOAD = {"jnotify.dll", "jnotify_64bit.dll","libjnotify.dylib", "libjnotify.so"};
	public static HashMap<String, String> LIBS_TODOWNLOAD = new HashMap<String, String>();
	
	public static void initReqLibs()
	{
		//init jnotify libs
		LIBS_TODOWNLOAD.put("jnotify.dll", LIBS_BASE_URL + "jnotify/" + "jnotify.dll" );
		LIBS_TODOWNLOAD.put("jnotify_64bit.dll", LIBS_BASE_URL + "jnotify/" + "jnotify_64bit.dll" );
		LIBS_TODOWNLOAD.put("libjnotify.dylib", LIBS_BASE_URL + "jnotify/" + "libjnotify.dylib" );
		LIBS_TODOWNLOAD.put("libjnotify.so", LIBS_BASE_URL + "jnotify/" + "libjnotify.so" );

		
	}
	
	
	
	
	
	
}
